﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using IDAL;
using Model;
namespace BLL
{
    public class shopCarBLL
    {
        private IshopCarDAL shopCarDAL = DALFactory.DateAccess.GetIshopCarDAL();
        public bool isExistGood(int id)
        {
            return shopCarDAL.isExistGood(id);
        }
        public shopCar GetShopCarByIDAndUid(int id, int uid)
        {
            return shopCarDAL.GetShopCarByIDAndUid(id, uid);
        }
        public int UpdatteNum(int id, int num)
        {
            return shopCarDAL.UpdateNum(id, num);
        }
        public void AddShoppingCar(int goodID, int uid, int num)
        {
            shopCarDAL.AddShoppingCar(goodID, uid, num);
        }
        public IQueryable<shopCar> GetShopCarByUid(int uid)
        {
            return shopCarDAL.GetShopCarByUid(uid);
        }
        public void DeleteSingleShoppingCar(int id)
        {
            shopCarDAL.DeleteSingleShoppingCar(id);
        }
        public shopCar GetShopCarByID(int id)
        {
            return shopCarDAL.GetShopCarByID(id);
        }
    }
}